/* const express = require('express')
const userRouter = require('./router/router.js')
const app = express()

//⑤	使用 app.use() 函数注册路由模块
app.use(userRouter);
//app.use(userRouter)

app.listen(8000, () => {
    console.log('8000 run router success')
}) */


const express = require('express')

const app = express()
const userRouter = require('./router/router')
const indexRouter = require('./indexRouter/router')

app.use('/api', userRouter)
app.use('/index', indexRouter)


app.listen(8000, () => {
    console.log('8000 running')
})